{{ template "base.html" .}}



{{ define "body" }}

<div class="">
    <table class="table table-striped table-bordered table-condensed table-hover">
        <caption>
            <h4>更新参数</h4>
        </caption>
        <thead>
            <tr>
                <td>参数</td>
                <td>默认值</td>
                <td>修改值</td>
            </tr>
        </thead>
        <tbody>
            <tr>
                <td> 读写方式 </td>
                <td> RO </td>
                <td>

                    <select>
                        <option selected value="">RO</option>
                        <option selected value="">RW</option>
                        <option selected value="">WO</option>
                    </select>

                </td>
            </tr>
            <tr>
                <td> ThreadNum </td>
                <td> 16 </td>
                <td>
                    <input value="16">


                </td>
            </tr>

            {{range $key,$value := .Params}}

            <tr>
                <td> {{ $key }}</td>
                <td>{{ $value }}</td>
                <td>
                    {{if eq $key "innodb_adaptive_hash_index"}}
                    <select>
                        <option selected value="{{ $value }}">{{ $value }}</option>
                    </select>
                    {{else if eq $key "innodb_random_read_ahead"}}
                    <select>
                        <option selected value="{{ $value }}">{{ $value }}</option>
                    </select>
                    {{else}}
                    <input value="{{ $value }}">

                    {{end}}
                </td>
            </tr>



            {{end}}

        </tbody>
    </table>

    <button class="btn btn-default" type="submit" name="id" value="">submit</button>
    <a class="btn btn-default" href=" ">cancel </a>

</div>



<script type="text/javascript" src="/static/js/jqplot/jqplot.cursor.min.js"></script>
<script type="text/javascript" src="/static/js/jqplot/jqplot.highlighter.min.js"></script>
<script type="text/javascript" src="/static/js/jqplot/jqplot.dateAxisRenderer.min.js"></script>
<script type="text/javascript" src="/static/js/jqplot/jqplot.categoryAxisRenderer.min.js"></script>
<script type="text/javascript" src="/static/js/jqplot/jqplot.canvasTextRenderer.min.js"></script>
<script type="text/javascript" src="/static/js/jqplot/jqplot.canvasAxisLabelRenderer.min.js"></script>
<script type="text/javascript" src="/static/js/jqplot/jqplot.canvasAxisTickRenderer.min.js"></script>
<script type="text/javascript" src="/static/js/jqplot/jqplot.barRenderer.min.js"></script>

<script type="text/javascript" src="/static/js/result10.js"></script>
<script type="text/javascript" src="/static/js/jquery.jqpagination.min.js"></script>

<!--  <script type="text/javascript">
 $(function() {
   ResultTimeline.init({
        result: {{ .Result.pk }},
        data: {{ .data }},
        all_metrics: {{.metric_meta}}, 
        metrics: [{{ range $metric := .default_metrics }}"{{ .metric }}", {{ end}}],
    });
}); 
</script> -->

<script type="text/javascript">
    $(document).ready(function () {

        $table_rows = $("#same  li");
        var table_row_limit = 10;
        var page_table = function (page) {

            var offset = (page - 1) * table_row_limit,
                limit = page * table_row_limit;

            $table_rows.hide();

            $table_rows.slice(offset, limit).show();

        }
        $('.pagination').jqPagination({
            max_page: Math.ceil($table_rows.length / table_row_limit),
            paged: page_table

        });
        page_table(1);

    });
</script>

{{ end }}